import request from '@/utils/request'

export function add(data) {
  return request({
    url: 'api/pokerActivateInfo',
    method: 'post',
    data
  })
}

export function startActivate(data) {
  return request({
    url: 'api/pokerActivateInfo/s',
    method: 'post',
    params: data
  })
}


export function endActivate(data) {
  return request({
    url: 'api/pokerActivateInfo/e',
    method: 'post',
    params: data
  })
}

export function endKingActivate(data) {
  return request({
    url: 'api/pokerActivateInfo/eKing',
    method: 'post',
    params: data
  })
}

export function testTaskGen() {
  return request({
    url: 'api/pokerActivateInfo/testTaskGen',
    method: 'post',
  })
}
export function del(ids) {
  return request({
    url: 'api/pokerActivateInfo/',
    method: 'delete',
    data: ids
  })
}

export function edit(data) {
  return request({
    url: 'api/pokerActivateInfo',
    method: 'put',
    data
  })
}

export function randmoCard() {
  return request({
    url: 'api/pokerActivateInfo/random',
    method: 'get',
  })
}


export function serverList() {
  return request({
    url: '/api/pokerServer/serverList',
    method: 'get',
  })
}


export default { add, edit, del, startActivate, randmoCard }
